
import { reg } from "./validate"
// Vuex 
import { useRouter } from "vue-router"
import { mapState, mapMutations, mapActions } from "vuex"
import { roleList } from "./index"
import { baseURL } from "@/api/request"
export const myMixins = {
    data() {
        return {
            reg,
            // roleList
            baseURL

        }
    },
    computed: {
        ...mapState([
            "userInfo"
        ])
    },
    methods: {
        ...mapActions([
            'changeUserInfoac'
        ])
    },
    created() {

        // console.log("全局混入")
    },
    setup(props, context) {
        const gotopage = (name) => {
            // 有待测试 
            const router = useRouter()
            router.push({ name })
        }

        return {
            gotopage
        }
    }
}